package DlgUtils;

import org.eclipse.swt.widgets.*;
import org.eclipse.swt.graphics.*;

public class Functions 
{
	public static Point GetScreenSize(Display display)
	{
		Rectangle bounds = display.getPrimaryMonitor().getBounds();
		return new Point(bounds.width, bounds.height);
	}
	
	public static void SetCenter(Display display, Shell shell)
	{
		Point size = GetScreenSize(display);
		shell.setLocation (size.x / 2, size.y / 2);
	}
}
